﻿
namespace Test30.Engine
{
    public class Power
    {
        public string Name => Type.Name;
        public object Appearance => Type.Appearance;
        public FlagCollection Flags => Type.Flags;
        public PowerType Type { get; }
        public int StrikeBonus { get; }
        public float DamageBonus { get; }
        public int ArmorBonus { get; }
        public int StatBonus { get; }
        public int SpeedBonus { get; }

        public Power(PowerType type)
        {
            Type = type;

            StrikeBonus = type.StrikeBonus.Roll();
            DamageBonus = type.DamageBonus.Roll() / 10.0f;
            ArmorBonus = type.ArmorBonus.Roll();
            StatBonus = type.StatBonus.Roll();
            SpeedBonus = type.SpeedBonus.Roll();
        }
    }
}
